//
//  CGroupMgr.h
//  wanzhaoIM
//
//  Created by liuyuantao on 15/5/22.
//  Copyright (c) 2015年 liuyuantao. All rights reserved.
//

#import <Foundation/Foundation.h>
@class CGroupModel;
@interface CGroupMgr : NSObject
//插入群
-(BOOL)insertGroup:(CGroupModel *)group;
//批量插入群
-(BOOL)batchInsertGroup:(NSArray *)groupList;
//删除群
-(BOOL)delGroup:(CGroupModel *)group;
//加载群
-(CGroupModel *)loadGroup:(NSString *)groupId;
//加载所有群和讨论组
-(NSArray *)loadAllGroupAndDiscussion;
//加载所有讨论组
-(NSArray *)loadAllDiscussList;
//加载所有群
-(NSArray *)loadAllGroup;
- (BOOL)delAllGroup;

- (BOOL)updateGroup:(CGroupModel *)group;
- (BOOL)delGroupWithGroupId:(NSString *)groupId;

- (BOOL)updateGroupIsDelWithGroupId:(NSString *)groupId IsDel:(BOOL)isDel;

- (NSArray *)searchGroupWithSeachStr:(NSString *)searchStr withGroupType:(NSInteger)groupType;

- (BOOL)isAvalableGroupWithGroupId:(NSString *)GroupId;
@end
